import defaultSetting from '@/setting.js'

const Layout = {
    layout: 'left1',// left1, left2 ,top, mix
    refresh: true,
    closeLeftSider: false,
    languageKey: localStorage.getItem("languageKey") ? [localStorage.getItem("languageKey")] : 'cn',
    languageData: undefined,
    themeColor: "#1890FF",
    windowLoading: false,
    pageLoading: false,
}
const Breadcrumb = {}

const Drawer = {
    openDrawer: false,
}

const Logo = {}

const Menu = {
    menuSelectedKeys: [],
    openKeys: [],
    menuTheme: 'dark',// light ; dark ; black
    menuMode: 'inline',// inline ; vertical

}
const MenuItem = {}

const TabView = {}

const state = {
    headerHeight: defaultSetting.layout.headerHeight,
    switchHeight: defaultSetting.layout.switchHeight,
    closeLeftSider: defaultSetting.layout.closeLeftSider,
    footerHeight: defaultSetting.layout.footerHeight,
    tagViewHeight: defaultSetting.layout.tagViewHeight,
    pageHeight: defaultSetting.layout.pageHeight,
    asideWidth: defaultSetting.layout.asideWidth,
    asideWidthMin: defaultSetting.layout.asideWidthMin,
    logoCloseWidth: defaultSetting.layout.logoCloseWidth,
    asideWidthMax: defaultSetting.layout.asideWidthMax,
    showAside: defaultSetting.layout.showAside,
    showTabView: defaultSetting.layout.showTabView,
    showPageView: defaultSetting.layout.showPageView,
    showHeader: defaultSetting.layout.showHeader,
    showFooter: defaultSetting.layout.showFooter,
    iframe: defaultSetting.iframe,
    iframeUrl: defaultSetting.iframeUrl,
    ...Layout,
    ...Menu,
    ...Drawer
}


export default {state: state}
